package edu.whu.demo.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import edu.whu.demo.domain.ActivityMember;
import edu.whu.demo.domain.ActivityMemberDTO;
import edu.whu.demo.exception.ActivityMemberException;

import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author 
 * @since 2022-11-24
 */
public interface IActivityMemberService extends IService<ActivityMember> {

    IPage<ActivityMember> getSigns(Long activityIdForSigns,
                                   Integer stage,
                                   Integer count,
                                   Integer pageNum,
                                   Integer pageSize);

    ActivityMember getSign(Long id);

    IPage<ActivityMemberDTO> getMemberState(Map<String, Object> condition,
                                            Integer pageNum,
                                            Integer pageSize);

    ActivityMember addSign(ActivityMember activityMember) throws ActivityMemberException;

    Integer updateMultipleSign(ActivityMember oldActivityMember, ActivityMember newActivityMember) throws ActivityMemberException;

    void updateSingleSign(ActivityMember activityMember) throws ActivityMemberException;

    void deleteSign(ActivityMember activityMember) throws ActivityMemberException;

    ActivityMember onlyLegalSign(Long activityId, Long uid) throws ActivityMemberException;


}
